package com.zcxy.sys.entity;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.zcxy.mybatis.bean.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.Max;
import javax.validation.constraints.NotEmpty;

/**
 * 物料属性
 *
 * @author zcc
 * @email 860474958@qq.com
 * @date 2020-09-12
 */
@Data
@TableName("sys_autocode_item")
@ApiModel(value = "SysAutocodeItem", description = "代码生成实体对象")
public class SysAutocodeItem extends BaseEntity {


        @ApiModelProperty(value = "主键", required = false)
        @TableId
        @Length(max = 50, message = "id 超出最大长度：50")
        private String id;


        @ApiModelProperty(value = "主表主键", required = false)
        @Length(max = 50, message = "parentId 超出最大长度：50")
        private String parentId;


        @ApiModelProperty(value = "数据库名称", required = false)
        @Length(max = 50, message = "columnName 超出最大长度：50")
        private String columnName;

        @ApiModelProperty(value = "数据库名称", required = false)
        @Length(max = 50, message = "columnNameB 超出最大长度：50")
        private String columnNameB;

        @ApiModelProperty(value = "数据库描述", required = false)
        @Length(max = 50, message = "description 超出最大长度：50")
        private String columnComment;


        @ApiModelProperty(value = "物理类型", required = false)
        @Length(max = 50, message = "type 超出最大长度：50")
        private String type;


        @ApiModelProperty(value = "数据字典", required = false)
        @Length(max = 255, message = "javaType 超出最大长度：255")
        private String javaType;


        @ApiModelProperty(value = "java名称", required = false)
        @Length(max = 255, message = "javaName 超出最大长度：255")
        private String javaName;


        @ApiModelProperty(value = "0非主键1主键", required = false)
        @Length(max = 255, message = "key 超出最大长度：255")
        private String pk;


        @ApiModelProperty(value = "列表需要展示：0不1需要", required = false)
        @Length(max = 255, message = "needList 超出最大长度：255")
        private String needList;


        @ApiModelProperty(value = "编辑显示：0 不1 显示", required = false)
        @Length(max = 255, message = "needEdit 超出最大长度：255")
        private String needEdit;


        @ApiModelProperty(value = "查询:0不1查询", required = false)
        @Length(max = 255, message = "needSearch 超出最大长度：255")
        private String needSearch;


        @ApiModelProperty(value = "匹配模式", required = false)
        @Length(max = 255, message = "searchType 超出最大长度：255")
        private String searchType;


        @ApiModelProperty(value = "控件类型", required = false)
        @Length(max = 255, message = "controlType 超出最大长度：255")
        private String controlType;


        @ApiModelProperty(value = "数据来源类型", required = false)
        @Length(max = 255, message = "controlDatasourseType 超出最大长度：255")
        private String controlDatasourseType;


        @ApiModelProperty(value = "排序", required = false)
        @Max(value = 100000, message = "sort：超出最大长度0")
        private Integer sort;


        @ApiModelProperty(value = "控件数据源值", required = false)
        @Length(max = 255, message = "controlDatasourse 超出最大长度：255")
        private String controlDatasourse;


        @ApiModelProperty(value = "校验规则", required = false)
        @Length(max = 32, message = "ruleId 超出最大长度：32")
        private String ruleId;


        @ApiModelProperty(value = "必填，0非必填，1必填", required = false)
        @Length(max = 255, message = "require 超出最大长度：255")
        private String required;


        @ApiModelProperty(value = "最大长度", required = false)
        @Max(value = 100000, message = "maxLength：超出最大长度0")
        private Integer maxLength;


        @ApiModelProperty(value = "0不是1是", required = false)
        @Length(max = 255, message = "needOrder 超出最大长度：255")
        private String needOrder;


        @ApiModelProperty(value = "0:asc 1: desc", required = false)
        @Length(max = 255, message = "orderType 超出最大长度：255")
        private String orderType;

}
